package org.flexthinker.binding.ui.form.binding
{
    import flash.display.DisplayObject;
    import flash.display.IBitmapDrawable;
    import flash.events.IEventDispatcher;

    /**
     * Describes visual forms having Bindable components, that are to be used for auto binding.
     *
     * <p>
     *     It exposes a collection of fields that could be used for auto binding.
     *     <code>FormBinding</code> uses these fields when <code>FormBinding.autoBind()</code> is called.
     * </p>
     * <p>
     *     <code>BindableUIForm</code> is extending the same interface <code>DisplayObject</code> is extending,
     *     so the form has to be a visual object.
     * </p>
     *
     * @see org.flexthinker.binding.ui.form.binding.Binder
     * @see org.flexthinker.binding.ui.form.binding.support.FormBinding
     */
    public interface BindableUIForm extends IBitmapDrawable, IEventDispatcher
    {
        /**
         * Returns the elements that could be used for auto binding.
         * @return
         *      Collection of <code>DisplayObject</code> elements.
         */
        function getBindableElements():Vector.<DisplayObject>;

    }
}
